﻿using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;

namespace DailyApp.WebAPI.DataModel
{
    //table特性用来给数据表命名，不加则默认以类名加s结尾
    [Table("AccountInfos")]
    public class AccountInfo
    {
        //[key]特性可以使其为主键,变量类型后加？表示其可为空
        /// <summary>
        /// 用户Id
        /// </summary>
        [Key]
        public int UserId { get; set; }

        /// <summary>
        /// 用户姓名
        /// </summary>
        public string Name { get; set; }

        /// <summary>
        /// 用户账号
        /// </summary>
        public string Account { get; set; }

        /// <summary>
        /// 密码
        /// </summary>
        public string Password { get; set; }
    }
}
